package com.ang.mybatisplus.base.mapper;

import com.ang.mybatisplus.base.entity.User;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author ssang
 * @since 2021-05-10
 */
public interface UserMapper extends BaseMapper<User> {
    //page要放在第一位，user要加@Param("user")注解
    IPage<User> selectPageXml(Page page, @Param("user") User user);

    List<User> listUserByMap(Map<String,String> map);

    List<User> listByUserParam(@Param("crypt") User user);

    List<User> listByUserNoParam(User user);

    List<User> listByNameParam(@Param("name") String name);
}
